#ifndef PLAYQUERY_H
#define PLAYQUERY_H

#include "config.h"
#include "DB_Manager.h"
#include "ui_playquery.h"
#include "editablemodel.h"




class PlayQuery : public QWidget, public Ui::PlayQuery
{
     Q_OBJECT
//
public:
PlayQuery( QWidget* = 0 );
void init( DB_Manager * dbin );
protected:
     void ReloadTables();
QSqlDatabase db;
QString one;
int nummer;
QStringList list;
QUrl url;
QSqlQueryModel *model_show;
QSqlQueryModel *model_edit;
bool having;
QSettings setter;
DB_Manager *line;
void FilluserQuery();
Qt::SortOrder  orderpaint;
private:
QStringListModel *menus;
int RowActive;
int Lnext;
signals:
public slots:
     void show_table( const QString t );
     void exec_query_user( const QString txtq = QString() );
     void export_show();
     void print_show();
     void show_paste_query( int i );
     void afterwrite();
     void user_play_query( int i );
     void save_user_query();
     void clear_user_query();
     void user_export_mysql();
     void updateMenu(); /* menu option from edit table update ! */
     void StructTable( QString t ) ;
     void OpenFileQuery();
     void ExecQueryList();
     void EditTable( const QString t);


};
//
#endif // PLAYQUERY_H

